package com.unittec.zk.provider.auth.service;

import java.util.List;

import org.springframework.stereotype.Service;

import com.unittec.zk.provider.auth.entity.SysRole;
import com.unittec.zk.provider.auth.entity.SysUserRole;
import com.unittec.zk.provider.auth.mapper.SysUserRoleMapper;
import com.unittec.zk.provider.root.ServiceRoot;

/**
 * @author Jason
 * @description 用户角色Service
 * @date 2019/11/07
 */
@Service
public class SysUserRoleService extends ServiceRoot<SysUserRoleMapper, SysUserRole> {

    /**
     * 根据用户ID获取角色
     *
     * @param userId
     * @return
     */
    public List<SysRole> getSysRoleByUserId(String userId) {
        return this.getMapper().getSysRoleByUserId(userId);
    }
}
